package org.jsola.hr.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.validator.constraints.Length;
import org.jsola.core.dto.BaseDTO;

import static org.jsola.hr.example.SalaryBillFieldsExample.E_BILL_ID;
import static org.jsola.hr.example.SalaryBillFieldsExample.E_FIELD_NAME;
import static org.jsola.hr.example.SalaryBillFieldsExample.E_FIELD_VALUE;
import static org.jsola.hr.example.SalaryBillFieldsExample.E_NEED_CALCULATE;
import static org.jsola.hr.example.SalaryBillFieldsExample.E_SORT;
import static org.jsola.hr.example.SalaryBillFieldsExample.M_BILL_ID_MAX;
import static org.jsola.hr.example.SalaryBillFieldsExample.M_FIELD_NAME_MAX;
import static org.jsola.hr.example.SalaryBillFieldsExample.M_FIELD_VALUE_MAX;
import static org.jsola.hr.example.SalaryBillFieldsExample.N_BILL_ID;
import static org.jsola.hr.example.SalaryBillFieldsExample.N_FIELD_NAME;
import static org.jsola.hr.example.SalaryBillFieldsExample.N_FIELD_VALUE;
import static org.jsola.hr.example.SalaryBillFieldsExample.N_NEED_CALCULATE;
import static org.jsola.hr.example.SalaryBillFieldsExample.N_SORT;

/**
 * 工资条自定义字段
 *
 * @author zhr
 */
@EqualsAndHashCode(callSuper = true)
@ApiModel(description = "新增【工资条自定义字段】的参数")
@Data
public class SalaryBillFieldsAddDTO extends BaseDTO {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(notes = N_BILL_ID, example = E_BILL_ID)
    @Length(max = 32, message = M_BILL_ID_MAX)
    private String billId;

    @ApiModelProperty(notes = N_FIELD_NAME, example = E_FIELD_NAME)
    @Length(max = 255, message = M_FIELD_NAME_MAX)
    private String fieldName;

    @ApiModelProperty(notes = N_FIELD_VALUE, example = E_FIELD_VALUE)
    @Length(max = 255, message = M_FIELD_VALUE_MAX)
    private String fieldValue;

    @ApiModelProperty(notes = N_NEED_CALCULATE, example = E_NEED_CALCULATE)
    private Boolean needCalculate;

    @ApiModelProperty(notes = N_SORT, example = E_SORT)
    private Integer sort;


}

